<!-- PageScript -->
<script><%- PageScript %></script>

<link rel="stylesheet" href="<%- Virtual_Path.Static %>main/css/mall.css"/>
<!-- cont -->
<div class="xiu-container">
    <div class="mall-hd clearfix">
        <ul class="mall-navi">
            <li>
                <a href="/mall/vip">会员</a>
            </li>
            <li class="on">
                <a href="/mall/motoring">座驾</a>
            </li>
            <li>
                <a href="/mall/guard">守护</a>
            </li>
        </ul>
    </div>
    <div class="mall-bd">
        <div class="mall-pro">
            <div class="mall-pro-bd">
                <div class="ad-mall-vip">
                    <a href="javascript:;"><img src="<%- Virtual_Path.Static %>main/image/mall/mall-zuojia.jpg"></a>
                </div>
            </div>
        </div>
        <div class="mall-pro">
            <div class="mall-pro-bd">
                <p class="pro-intro-help">
                    <a href="<%- Virtual_Path.Main %>help/help-1-3" target="_blank">等级介绍>></a>
                </p>
                <ul class="clearfix pro-list-show pro-list-zuojiainfo" id="J_ForMount_Info">
                </ul>
            </div>
        </div>
    </div>
</div>
<script>$(function () {
        var mounts = '';
        if (_PageData.MountsList.length <= 0) {
            mounts += "<li class='listitem'>";
            mounts += '<div class="pro-info">';
            mounts += '<div class="pro-mark">';
            mounts += '暂无座驾！';
            mounts += '</div>';
            mounts += '</div>';
            mounts += '</li>';
        }
        _.forEach(_PageData.MountsList, function (ThisValue) {
            mounts += '<li class="listitem">' +
                    '<div class="pro-info">' +
                    '<div class="pro-mark">' +
                    '<span class="mark-bg-1">'+ThisValue.Level_Name+'及以上</span>' +
                    '</div>' +
                    '<div class="pro-img">' +
                    '<img src="' + _VirtualPath.Static + 'main/image/mount/car'+ThisValue.id+'.png" alt="'+ ThisValue.Name +'" />' +
                    '</div>' +
                    '<h2>' + ThisValue.Name + '</h2>' +
                    '<div class="price-info">' +
                    '<p><img src="' + _VirtualPath.Static + 'main/image/mall/ico-coin.png" class="img-ver"/>' + ThisValue.Price + '／月</p>' +
                    '</div>' +
                    '<div class="buy-btn"> <input name="ItemId" value="' + ThisValue.id + '" type="hidden">' +
                    '<a href="javascript:;" class="mall-btn-buy J_Mount_buy">购买</a>' +
                    '</div>' +
                    '</div>' +
                    '</li>';
        });
        $('#J_ForMount_Info').empty().append(mounts);

        $('.J_Mount_buy').on('click', function () {
            if(!_StateData.IsLogin){
                $.CommonMain.Login('In');
                return true;
            }
            $.CommonMain.User_MountsPurchase($(this).parent().find("input[name=ItemId]").val(), function () {
                $.CommonMain.Modal_Tip("座骑购买成功!");
            });
        });
    });
</script>